<?php

$db['account']=array (
  'columns' =>
  array (
    'user_id' =>
    array (
      'type' => 'number',
      'extra' => 'auto_increment',
      'pkey' => true,
      'label' => '用户ID',
    ),
    'login_account' =>
    array (
      'required' => true,
      'default' => 0,
      'label' => '登录名',
      //'sdfpath' => 'member_lv/member_group_id',
      'width' => 75,
      'order' => 40,
      'type' => 'varchar(50)',
      'editable' => true,
      'filtertype' => 'bool',
      'filterdefault' => 'true',
      'in_list' => true,
      'default_in_list' => true,
    ),
     'email' =>
    array (
      'required' => true,
      'default' => 0,
      'label' => '邮箱',
      'width' => 75,
      'order' => 40,
      'type' => 'varchar(50)',
      'editable' => true,
      'filtertype' => 'bool',
      'filterdefault' => 'true',
      'in_list' => true,
      'default_in_list' => true,
    ),
     'mobile' =>
    array (
      'required' => true,
      'default' => 0,
      'label' => '手机号',
      'width' => 75,
      'order' => 40,
      'type' => 'int(11)',
      'editable' => true,
      'filtertype' => 'bool',
      'filterdefault' => 'true',
      'in_list' => true,
      'default_in_list' => true,
    ),
     'openid' =>
    array (
      'required' => true,
      'default' => 0,
      'label' => '微信id',
      'width' => 75,
      'order' => 40,
      'type' => 'varchar(120)',
      'editable' => true,
      'filtertype' => 'bool',
      'filterdefault' => 'true',
      'in_list' => true,
      'default_in_list' => true,
    ),      
    'name' =>
    array (
      'type' => 'varchar(50)',
      'label' => '姓名',
      'width' => 75,
      'sdfpath' => 'contact/name',
      'searchtype' => 'has',
      'editable' => true,
      'filtertype' => 'normal',
      'filterdefault' => 'true',
      'in_list' => true,
      'is_title'=>true,
      'default_in_list' => false,
    ),





     'wxname' =>
    array (
      'type' => 'varchar(255)',
      'label' => '微信号',
      'width' => 75,
      'editable' => false,
      'filtertype' => 'normal',
      'in_list' => false,
    ),



    'addon' =>
    array (
      'type' => 'longtext',
      'editable' => false,
      'comment' => '会员额外序列化信息',
    ),
   
    'advance' =>
    array (
      'type' => 'money',
      'default' => '0.00',
      'required' => true,
      'label' => '预存款',
      'sdfpath' => 'advance/total',
      'width' => 110,
      'editable' => false,
      'filtertype' => 'number',
      'in_list' => true,
      'comment' => '会员账户余额',
    ),
    'advance_freeze' =>
    array (
      'type' => 'money',
      'default' => '0.00',
      'sdfpath' => 'advance/freeze',
      'required' => true,
      'editable' => false,
      'comment' => '会员预存款冻结金额',
    ),
    'point_freeze' =>
    array (
      'type' => 'number',
      'default' => 0,
      'required' => true,
      'sdfpath' => 'score/freeze',
      'editable' => false,
      'comment' => '会员当前冻结积分(暂时停用)',
    ),

    'reg_ip' =>
    array (
      'type' => 'varchar(16)',
      'label' => '注册IP',
      'width' => 110,
      'editable' => false,
      'in_list' => true,
      'comment' => '注册时IP地址',
    ),
    'regtime' =>
    array (
      'label' => '注册时间',
      'width' => 75,
      'type' => 'time',
      'editable' => false,
      'filtertype' => 'time',
      'filterdefault' => true,
      'in_list' => true,
      'default_in_list' => true,
      'comment' => '注册时间',
    ),
    'state' =>
    array (
      'type' => 'tinyint(1)',
      'default' => 0,
      'required' => true,
      'label' => '验证状态',
      'width' => 110,
      'editable' => false,
      'in_list' => false,
      'comment' => '会员验证状态',
    ),

    'disabled' =>
    array (
      'type' => 'bool',
      'default' => 'false',
      'editable' => false,
    ),
    'remark' =>
    array (
      'label' => '备注',
      'type' => 'text',
      'width' => 75,
      'in_list' => true,
    ),
   
  

      'pay_password' => array (
          'type' => 'varchar(32)',
          'required' => false,
          'comment' => '支付密码',
      ),
   
    'invite_mem_fid'       => array (
            'type'      => 'number',
            'label'     => '父级/上级',
            'width'     => 100,
            'default'   => 0,			
            'in_list' => true,
            'default_in_list' => true,			
        ),

   ),
  'comment' => '用户表',
  'index' =>
  array (
    'ind_email' =>
    array (
      'columns' =>
      array (
        0 => 'email',
      ),
    ),
    'ind_login_account' =>
    array (
      'columns' =>
      array (
        0 => 'login_account',
      ),
    ),
    'ind_mobile' =>
    array (
      'columns' =>
      array (
        0 => 'mobile',
      ),
    ),
    'ind_openid' =>
    array (
      'columns' =>
      array (
        0 => 'openid',
      ),
    ),      
  ),
  'engine' => 'innodb',
  'version' => '$Rev: 42799197 $',
  'comment' => '用户表',
);
